From ab8ea9334afd3c3678aed1d373965bfe902fbfb1 Mon Sep 17 00:00:00 2001 From: Keir Fraser Date: Fri, 21 Mar 2008 09:45:34 +0000 Subject: [PATCH] vmx: Setting of VMCS IO_BITMAP_B must take account of fact that hvm_io_bitmap is now a long[] rather than a char[]. Bug spotted by Dexuan Cui Signed-off-by: Keir Fraser --- xen/arch/x86/hvm/vmx/vmcs.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/xen/arch/x86/hvm/vmx/vmcs.c b/xen/arch/x86/hvm/vmx/vmcs.c index ac8cda22d4..bee9eb1deb 100644 --- a/xen/arch/x86/hvm/vmx/vmcs.c +++ b/xen/arch/x86/hvm/vmx/vmcs.c @@ -473,8 +473,8 @@ static int construct_vmcs(struct vcpu *v) } /* I/O access bitmap. */ - __vmwrite(IO_BITMAP_A, virt_to_maddr(hvm_io_bitmap)); - __vmwrite(IO_BITMAP_B, virt_to_maddr(hvm_io_bitmap + PAGE_SIZE)); + __vmwrite(IO_BITMAP_A, virt_to_maddr((char *)hvm_io_bitmap + 0)); + __vmwrite(IO_BITMAP_B, virt_to_maddr((char *)hvm_io_bitmap + PAGE_SIZE)); /* Host GDTR base. */ __vmwrite(HOST_GDTR_BASE, GDT_VIRT_START(v)); -- 2.30.2